bitkeeper revision 1.1062.1.4 (40f071adpADaHVr_bSwBDtkumtyL-Q)
authoriap10@labyrinth.cl.cam.ac.uk <iap10@labyrinth.cl.cam.ac.uk>
Sat, 10 Jul 2004 22:46:05 +0000 (22:46 +0000)
committeriap10@labyrinth.cl.cam.ac.uk <iap10@labyrinth.cl.cam.ac.uk>
Sat, 10 Jul 2004 22:46:05 +0000 (22:46 +0000)
minor UI improvements to 'xm'

tools/python/xen/xm/main.py
tools/python/xen/xm/opts.py

index 8f0cdb247e3727c2c7c1ccfefe1db5ddf9ddcef8..771b613107818137575a4faeb0a9889b0ca2cbe3 100644 (file)
@@ -78,11 +78,10 @@ class Xm:
         """
         self.name = args[0]
         if len(args) < 2:
-            self.err("Missing command\nTry '%s help' for more information."
-                     % self.name)
-        help = self.helparg(args)
+               args.append('help')
+       help = self.helparg(args)
         p = self.getprog(args[1], self.unknown)
-        if help:
+        if help or len(args) < 2: 
             p.help(args[1:])
         else:
             p.main(args[1:])
index 9bae32e0822cb31e2ecdc3064e9b3643a5f274c3..d66d30a7a32a46edde85cdaa3725da98aff5d427 100644 (file)
@@ -331,6 +331,7 @@ class Opts:
             else:
                 p = self.vals.defaults
             if os.path.exists(p):
+               print 'Using config file %s\n' % (p)
                 self.load(p, help)
                 break
         else: